package com.eastfair.builder.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.eastfair.boot.request.PageParams;
import com.eastfair.boot.service.SuperService;
import com.eastfair.builder.dto.ReportSpaceDTO;
import com.eastfair.builder.entity.ReportSpace;
import com.eastfair.builder.vo.ExhibitorVO;
import com.eastfair.builder.vo.ReportSpaceVO;
import com.eastfair.home.dto.ReportSpaceAuditDTO;

import java.util.List;
import java.util.Map;

/**
 * <p>
 * 业务接口
 * 报馆记录表
 * </p>
 *
 * @author dq
 * @date 2022-08-06
 */
public interface ReportSpaceService extends SuperService<ReportSpace> {

    /**
     * 分页查询报馆记录VO.
     *
     * @param pageParams the page params
     * @return the page
     */
    IPage<ReportSpaceVO> listReportSpaceVOs(PageParams<ReportSpaceDTO> pageParams);

    /**
     * ID获取报馆详情.
     *
     * @param id the id
     * @return the report space vo by id
     */
    ReportSpaceVO getReportSpaceVOById(Long id);

    /**
     * 展商ID查询报馆列表.
     *
     * @param exhibitorId the exhibitor id
     * @return the list
     */
    List<ReportSpace> listByExhibitorId(Long exhibitorId);

    /**
     * 展商ID批量查询报馆列表.
     *
     * @param exhibitorIds the exhibitor ids
     * @return the list
     */
    List<ReportSpace> listByExhibitorIds(List<Long> exhibitorIds);

    /**
     * 展商ID批量查询报馆map.
     *
     * @param exhibitorIds the exhibitor ids
     * @return the map key-展商ID value-报馆记录
     */
    Map<Long, ReportSpace> getMapByExhibitorIds(List<Long> exhibitorIds);

    /**
     * 查询报馆记录列表.
     *
     * @param query the query
     * @return the list
     */
    List<ReportSpace> listReportSpaces(ReportSpaceDTO query);

    /**
     * 展商ID查询报馆记录.
     *
     * @param exhibitorId the exhibitor id
     * @return the by exhibitor id
     */
    ReportSpace getByExhibitorId(Long exhibitorId);

    /**
     * 报馆id查询展位保证金.
     *
     * @param id the report space id
     * @return the site bond for report space
     */
    ExhibitorVO getShouldEarnestMoneyById(Long id);

    /**
     * 保存报馆记录.
     *
     * @param saveDTO the save dto
     * @return the boolean
     */
    ReportSpace saveReportSpace(ReportSpaceDTO saveDTO);

    /**
     * 更新报馆记录.
     *
     * @param saveDTO the save dto
     * @return the boolean
     */
    boolean updateReportSpace(ReportSpaceDTO saveDTO);

    /**
     * 提交报馆记录.
     *
     * @param reportSpaceId the space dto
     * @return the boolean
     */
    boolean submitReportSpace(Long reportSpaceId);

    /**
     * 更新报馆记录状态为已提交.
     *
     * @param reportSpace the report space id
     * @return the boolean
     */
    ReportSpace updateReportSpaceStatusSubmit(ReportSpace reportSpace);

    /**
     * 更新报馆审核状态.
     *
     * @param reportSpaceDTO the report space
     * @return the boolean
     */
    boolean updateReportSpaceAuditStatus(ReportSpaceDTO reportSpaceDTO);

    /**
     * 更新场馆审核结果.
     *
     * @param reportSpaceDTO the report space dto
     * @return the boolean
     */
    boolean updateVenueAuditStatus(ReportSpaceDTO reportSpaceDTO);

    /**
     * 报馆取消申请.
     *
     * @param reportSpaceId the report space id
     * @return the boolean
     */
    boolean updateReportSpaceAuditStatusNotSubmit(Long reportSpaceId);

    /**
     * 报馆ID删除报馆记录.
     *
     * @param id the id
     * @return the boolean
     */
    boolean removeReportSpaceById(Long id);

    /**
     * 展商展位ID删除报馆信息
     *
     * @param exhibitorId the exhibitor id
     * @return the boolean
     */
    boolean removeByExhibitorId(Long exhibitorId);

    /**
     * 展商展位ID列表删除报馆信息
     *
     * @param exhibitorIdList the exhibitor id list
     * @return the boolean
     */
    boolean removeByExhibitorIdList(List<Long> exhibitorIdList);

    /**
     * 发送图纸审核通过信息
     *
     * @param reportSpaceId the report space id
     * @return the boolean
     */
    @Deprecated
    boolean sendDrawingAuditMsg(Long reportSpaceId);

    /**
     * 异步发送图纸审核通过信息
     *
     * @param reportSpaceId the report space id
     */
    @Deprecated
    void asyncSendDrawingAuditMsg(Long reportSpaceId);

    /**
     * 发送图纸审核通过信息
     *
     * @param reportSpaceAudit the report space audit
     * @return the boolean
     */
    boolean sendDrawingAuditMsg(ReportSpaceAuditDTO reportSpaceAudit);

    /**
     * 异步发送图纸审核通过信息
     *
     * @param reportSpaceAudit the report space audit
     */
    void asyncSendDrawingAuditMsg(ReportSpaceAuditDTO reportSpaceAudit);
}
